# EllipticCurve.py
# 绘制椭圆曲线
# -*- coding: utf-8 -*-
"""
Created on 2021

@author: Ximing
"""

import numpy as np
import matplotlib.pyplot as plt

y1, x1 = np.ogrid[-5:5:100j, -5:5:100j]
cs=plt.contour(x1.ravel(), y1.ravel(), pow(y1, 2) - pow(x1, 3) -3, [0])

ax = plt.gca()
ax.spines['top'].set_color('none')
ax.spines['right'].set_color('none')
ax.spines['left'].set_position(('data',0))
ax.spines['bottom'].set_position(('data',0))

plt.grid()
plt.show()